package com.pangu.task;

import com.pangu.service.ActionException;
import com.pangu.task.mark.ATaskMark;

/**
 * 操作结果的封装
 * <p/>
 * Created by cxlin
 */
public class OperateResult {

    // 标示执行的一个结果数据。
    private Object resultData;
    // 这个任务是哪个
    private ATaskMark taskMark;
    // 如果执行过程用抛出服务异常那边将被保留
    // 并将任务标记为error
    private ActionException actionException;
    // 附件
    private Object attach;

    public OperateResult(ATaskMark taskMark, Object resultData) {
        this.taskMark = taskMark;
        this.resultData = resultData;
    }

    public OperateResult(ATaskMark taskMark) {
        super();
        this.taskMark = taskMark;
    }

    public Object getResultData() {
        return resultData;
    }

    public void setResultData(Object resultData) {
        this.resultData = resultData;
    }

    public ATaskMark getTaskMark() {
        return taskMark;
    }

    public void setTaskMark(ATaskMark taskMark) {
        this.taskMark = taskMark;
    }

    public ActionException getActionException() {
        return actionException;
    }

    public void setActionException(ActionException actionException) {
        this.actionException = actionException;
    }

    public Object getAttach() {
        return attach;
    }

    public void setAttach(Object attach) {
        this.attach = attach;
    }
}
